package org.sgx.gapigui.client.state;
/**
 * using gwt History this class let navigate to gwtgapi-gui app main states/places
 * @author sg
 *
 */
public interface AppStateManager {
	

	public static final String HISTORY_PREFIX = "page";

	public static final String STATE_INTRODUCTION = "introduction";  
	
	public static final String STATE_FT_TABLES="fttables";
	public static final String STATE_FT_QUERIES = "ftqueries";  
	
	public static final String STATE_BOOKS_SEARCH = "bookssearch";
	
	public static final String STATE_URLSHORTENER_VIEW1 = "urlshortener1";
	
	public static final String STATE_DRIVE_FILES1 = "drivefiles1";
	
	public static final String STATE_YOUTUBE_SEARCH1 = "youtube_search1";
	
	public static final String STATE_DRIVE_FILE_ENCRYPTOR = "drive_file_encryptor";
	
	public static final String  STATE_PAGESPEED1="pagespeed1"; 	
	
	public static final String STATE_DEFAULT=STATE_INTRODUCTION;
	
	public static final String[] ALL_STATES={STATE_INTRODUCTION, STATE_FT_TABLES, 
		STATE_FT_QUERIES, STATE_BOOKS_SEARCH, STATE_URLSHORTENER_VIEW1, STATE_PAGESPEED1};
	
	
	
	void navigate(String name); 
	
	/**
	 * gwts the state name from url. if not state is found returns null. 
	 * @param url
	 * @return
	 */
	String urlContainsState(String url); 
	void addStateListener(StateListener l); 
}

